package loader

fun main(args: Array<String>) {
//    println(System.getProperty("sun.boot.class.path"))

    val myload = MyLoader("D:\\Android\\IdeaProj\\JaveDemo\\src")
    val clazz = myload.loadClass("PreLoadClass")
    if(clazz != null){
        val obj = clazz.newInstance()
        println(obj.javaClass.classLoader)
        val sayMethod = clazz.getDeclaredMethod("say", Void.TYPE)
        if(sayMethod != null){
            sayMethod.invoke(obj, null)
        }
    }
}